<include file="Common@Public:header"/>

		<div class="s_middle">
			<div class="history">
				<h2>{$category.title}</h2>
			</div>
			<div class="middle_c">
				<div class="mid_c_d">
					<div class="mid_c_d01" style="width: 100%;">
				
				    <form id="form" action="" method="post" class="am-form am-form-horizontal">
                        <div class="am-cf am-u-md-12 am-margin-top am-tabs" data-am-tabs="{noSwipe: 1}">
                            <!-- 表单 -->
                            <div class="am-tabs-bd">
                                <include file="Public/form" />
							<p style="margin-left:12px;line-height:40px;"><span class="_p_span_l">验证码 </span><input placeholder="请输入验证码"  errormsg="请填写5位验证码" nullmsg="请填写验证码" datatype="*5-5" name="verify" type="text" class="_p_span_r" style="width:25%;height:px;"><span><img class="verifyimg reloadverify" alt="点击切换" src="{:U('User/Public/verify')}" style="float: none;cursor:pointer; height:40px; position:relative; top:20px;"></span></p>	
                                
				<script type="text/javascript" src="__PUBLIC__/core.js"></script>
                    <script type="text/javascript">

              $(document)
                .ajaxStart(function(){
                  $("button:submit").addClass("am-btn-loading").attr("disabled", true).text('loading...');
                })
                .ajaxStop(function(){
                  $("button:submit").removeClass("am-btn-loading").attr("disabled", false).text('登  入');
                });


              $("form").submit(function(){
                var self = $(this);
                $.post(self.attr("action"), self.serialize(), success, "json");
                return false;

                function success(data){
                  if(data.status){
                    window.location.href = data.url;
                  } else {
                    self.find(".Validform_checktip").addClass('am-alert').text(data.info);
                    setTimeout(function(){
                      self.find(".Validform_checktip").removeClass('am-alert').text('');
                    },3000);
                    //刷新验证码
                    $(".reloadverify").click();
                  }
                }
              });

              $(function(){
                var verifyimg = $(".verifyimg").attr("src");
                    $(".reloadverify").click(function(){
                        if( verifyimg.indexOf('?')>0){
                            $(".verifyimg").attr("src", verifyimg+'&random='+Math.random());
                        }else{
                            $(".verifyimg").attr("src", verifyimg.replace(/\?.*$/,'')+'?'+Math.random());
                        }
                    });
              });
            </script>
                                <div class="am-form-group">
                                    <div class="am-u-sm-10 am-u-sm-offset-2">
                                        <button class="am-btn am-btn-primary submit-btn ajax-post" type="submit" target-form="am-form-horizontal">确 定</button>
										 <button class="am-btn am-btn-primary submit-btn ajax-post hidden" type="reset" target-form="am-form-horizontal">重 置</button>
                                        <input type="hidden" name="job_id" value="{:I('job_id')}" />
                                    </div>
                                </div>
                            </div>
                        </div>
                    </form>
					</div>
				</div>
			</div>
		</div>

<include file="Common@Public:footer"/>	
		

		
	</div>
</body>
</html>